<?php
// Nawattapon : check loged in
  $admin_folder = explode('/',$_SERVER['SCRIPT_NAME']);
  $lenght = count($admin_folder);
  if($admin_folder[($lenght-2)]!='admin'){
    if(!(isset($_SESSION['username']) AND isset($_SESSION['admin']))){
      header("location: ".ADMIN);
    }
  }
// Nawattapon
?>
<html>
<head>
  <title>Design Sentiment / Admin</title>
  <link rel="shortcut icon" href="<?=URL?>/favicon.ico" />
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>

  <!-- JQuery -->

  <script type="text/javascript" src="<?=ADMIN?>/js/jquery-1.5.min.js"></script>
  <script type="text/javascript" src="<?=ADMIN?>/js/jquery-ui.min.js"></script>
  <link rel="stylesheet" type="text/css" href="<?=ADMIN?>/js/jquery-ui.css" media="screen" />

  <script type="text/javascript" src="<?=ADMIN?>/js/jquery.expander.js"></script>

  <!-- Fancy Box-->

  <script type="text/javascript" src="<?=ADMIN?>/js/fancybox/jquery.easing-1.3.pack.js"></script>
  <script type="text/javascript" src="<?=ADMIN?>/js/fancybox/jquery.mousewheel-3.0.4.pack.js"></script>
  <script type="text/javascript" src="<?=ADMIN?>/js/fancybox/jquery.fancybox-1.3.4.js"></script>
  <link rel="stylesheet" type="text/css" href="<?=ADMIN?>/js/fancybox/jquery.fancybox-1.3.4.css" media="screen" />

  <!-- date picker -->

  <link rel="stylesheet" type="text/css" media="all" href="<?=ADMIN?>/js/calendar/jsDatePick_ltr.min.css" />
  <script type="text/javascript" src="<?=ADMIN?>/js/calendar/jsDatePick.min.1.3.js"></script>

  <!-- tinyMCE -->
  <script language="javascript" type="text/javascript" src="<?=ADMIN?>/js/tinymce/jscripts/tiny_mce/tiny_mce.js"></script>
  <script language="javascript" type="text/javascript" src="<?=ADMIN?>/js/tinymce/init.js"></script>

  <script type="text/javascript" src="<?=ADMIN?>/js/function.js"></script>

  <link rel="stylesheet" href="<?=ADMIN?>/style.css" type="text/css" media="screen" />
</head>

<body>